﻿<UserControl x:Class="Weather.WeatherWidget"
             xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
             xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml" xmlns:Properties="clr-namespace:Weather.Properties" FontWeight="Light" Background="#327f84">
    <!--<UserControl.Background>
        <LinearGradientBrush StartPoint="1,0" EndPoint="0,0">
            <GradientStop Color="#52b4bd" Offset="0"/>
            <GradientStop Color="#409fa5" Offset="1"/>
        </LinearGradientBrush>
    </UserControl.Background>-->
    <UserControl.ContextMenu>
        <ContextMenu>
            <MenuItem Name="RefreshItem" Header="{x:Static Properties:Resources.RefreshItem}" Click="RefreshItemClick"/>
            <MenuItem Name="OptionsItem" Header="{x:Static Properties:Resources.OptionsItem}" Click="OptionsItemClick"/>
        </ContextMenu>
    </UserControl.ContextMenu>
    <UserControl.Resources>
        <Storyboard x:Key="TileAnim">
            <DoubleAnimation Storyboard.TargetName="ForegroundGridTranslation" Storyboard.TargetProperty="Y" From="0" To="-50" Duration="0:0:0.3" AccelerationRatio="0.3" DecelerationRatio="0.7"/>
            <DoubleAnimation Storyboard.TargetName="ForegroundGridTranslation" Storyboard.TargetProperty="Y" BeginTime="0:0:2.5" To="0" Duration="0:0:0.3" AccelerationRatio="0.3" DecelerationRatio="0.7"/>
        </Storyboard>
    </UserControl.Resources>
    <Grid ClipToBounds="True">
        <TextBlock Name="Location" Text="New York" Foreground="White" FontSize="28" VerticalAlignment="Bottom" HorizontalAlignment="Left" Margin="10,0,10,10" TextTrimming="CharacterEllipsis"/>
        <Grid Name="ForegroundGrid">
            <Grid.RenderTransform>
                <TranslateTransform x:Name="ForegroundGridTranslation"/>
            </Grid.RenderTransform>
            <Grid.Background>
                <LinearGradientBrush StartPoint="1,0" EndPoint="0,0">
                    <GradientStop Color="#FF4DB4B9" Offset="0"/>
                    <GradientStop Color="#FF3F99A1" Offset="1"/>
                </LinearGradientBrush>
            </Grid.Background>
            <DockPanel>
                <Image Name="WeatherIcon" DockPanel.Dock="Left" Source="/Weather;component/Resources/weather_1.png" Width="120"/>
                <StackPanel Margin="0,20,10,20">
                    <TextBlock Name="Temperture" Text="0° Sunny" FontSize="30" Foreground="White" TextTrimming="CharacterEllipsis"/>
                    <TextBlock Name="FirstDay" Text="Wednesday: 0° Sunny" FontSize="18" Foreground="White" TextTrimming="CharacterEllipsis"/>
                    <TextBlock Name="SecondDay" Text="Thursday: 0° Sunny" FontSize="18" Foreground="White" TextTrimming="CharacterEllipsis"/>
                    <TextBlock Name="ThirdDay" Text="Friday: 0° Sunny" FontSize="18" Foreground="White" TextTrimming="CharacterEllipsis"/>
                </StackPanel>
            </DockPanel>
            <TextBlock Text="Weather" Foreground="White" FontSize="14" VerticalAlignment="Bottom" HorizontalAlignment="Left" Margin="10,0,0,10"/>
        </Grid>
        <Rectangle Height="Auto" HorizontalAlignment="Stretch" Name="rectangle1" Stroke="#71FFFFFF" VerticalAlignment="Stretch" Width="Auto" StrokeThickness="1" />
    </Grid>
</UserControl>
